import { Draw } from "../../../Draw/Draw";
import { IKonva } from "../../../Interface/IKonva";

export function lineDragEnd(e: IKonva.Event, draw: Draw) {
  // 直线拖拽，肯定会脱离 Shape 节点，应该重置 startPoints endPoints
  const line = e.currentTarget;
  line.setAttrs({ startShape: null, endShape: null });
  draw.render();
}
